package tests;

import java.util.LinkedList;

import bookworm.BestReviewersRecommendationsRetriever;
import bookworm.Book;

public class TestBookRecommendationsRetreiver 
{
	public static void main(String args[])
	{
		
		BestReviewersRecommendationsRetriever retreivesBookRecommendations = 
				new BestReviewersRecommendationsRetriever();
		LinkedList<String> topReviewerNames = retreivesBookRecommendations.getBestReviewersUserName();
		
		for(int i = 0; i < topReviewerNames.size(); i++)
		{
			System.out.println("////////////////" + topReviewerNames.get(i) + " recommended these books:");
			LinkedList<Book> booksRecommended = 
					retreivesBookRecommendations.getAllBookRecommendationsFromTopReviewer(topReviewerNames.get(i));
			for(int j = 0; j < booksRecommended.size(); j++)
			{
				Book bookRecommended = booksRecommended.get(j);
				System.out.println(bookRecommended.getBookName());
			}
		}
		
	}

}
